<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script src="../js/jquery.min.js"></script>
</head>
<script>
function del(id){
	
	$.getJSON("/savedel/movie/del?id="+id,function(result){
	result = eval("("+result+")");  
	
	alert(result.rsMsg);
	if(result.rscode=="1"){
	$("#"+id).remove;
	}
	})
}
</script>
<body>
<form>
<table  width="30%"  border="1" >

<tr>
<td>电影名</td>
<td>主演</td>
<td>导演</td>
<td>价格</td>
<td>操作</td>
</tr>

<#list list as li>
<tr id="${li.id}">
<td>${li.name}</td>
<td>${li.actor}</td>
<td>${li.dir}</td>
<td>${li.price}</td>
<td><a href="/savedel/movie/id?id=${li.id}"><input type="button" value="修改">
</input>

<input type="button" onclick="del(${li.id})" value="删除"></input></td>
</tr>
</#list>

</table>
<a href="/savedel/movieadd.ftl"><input type="button" value="增加" id="add"></input></a>
</from>
</body>
</html>

